約 3,757,321 件
https://w.atwiki.jp/naobe/pages/110.html
言語に戻る 配列の代入 $b = \@b; @a = @{$b}; push @a,10; 上記では、@bをコピーしたものを@aに設定する(@aと@bはアドレスが異なる)。よって、10は@bには挿入されない。 perldoc 項目 説明 perldoc perl 調査項目のリストアップ perldoc perlrun 起動オプションを調べる perldoc perlsyn 文法を調べる perldoc Class Struct モジュールを調べる perldoc -m Class Struct モジュールのソースコードを表示する perldoc -l Class Struct モジュールのディレクトリを調べる perldoc -f open ビルトイン関数を調べる perlpod perlのドキュメントフォーマット。マークアップ言語。Podのマークアップは3種類のパラグラフからなる。 ordinary, verbatim, command。 Ordinary Paragraph パッケージ モジュールのディレクトリを調べる for $path ( @INC ) { print $path, "\n"; } 時刻関連 1 #!/usr/bin/perl 2 3 use strict; 4 use Time Local; 5 use Time localtime; 6 7 # 現在の時刻を求める 8 my $tmref = localtime(); 9 printf( "本日 %d/%d/%d %d %d %d\n", $tmref- year()+1900,$tmref- mon()+1,$tmref- mday(),$tmref- hour(),$tmref- min(),$tmref- sec()); 10 print "\n"; 11 # 通算秒を求める 12 my $time = timegm(0,0,0,1,0,1970); 13 print "1970/1/1 00 00 00 GM 通算秒 ", $time,"\n"; 14 print "\n"; 15 # 指定日の1日前を求める 16 $time = timelocal(0,0,0,1,2,2016); 17 $tmref = localtime($time); 18 printf( "指定日 %d/%d/%d %d %d %d\n", $tmref- year()+1900,$tmref- mon()+1,$tmref- mday(),$tmref- hour(),$tmref- min(),$tmref- sec()); 19 20 $time -= 60 * 60 * 24; 21 $tmref = localtime($time); 22 printf( "1日前 %d/%d/%d %d %d %d\n", $tmref- year()+1900,$tmref- mon()+1,$tmref- mday(),$tmref- hour(),$tmref- min(),$tmref- sec()); 【実行結果】 [suna@athlon4 perl]$ ./time.pl 本日 2013/5/18 9 20 49 1970/1/1 00 00 00 GM 通算秒 0 指定日 2016/3/1 0 0 0 1日前 2016/2/29 0 0 0 Carp 警告を出力する。例外を出力して停止する。 use Carp qw(croak); sub sub1 { print "aaa\n"; croak( "Exception occured."); print "bbb\n"; } sub1; 【実行結果】 [foo@athlon4 perl]$ ./7.pl aaa Exception occured. at ./7.pl line 7 main sub1() called at ./7.pl line 11 構造体 構造体のフィールドは、種類を示す。$ スカラ、@ 配列、% ハッシュ 1 #!/usr/bin/perl -w 2 # 構造体を使う 3 4 use Class Struct; 5 use Data Dumper; 6 use strict; 7 8 struct Person = { 9 name = $ , 10 father = $ , 11 mother = $ 12 }; 13 14 my $p1 = new Person; 15 $p1- name( john ); 16 $p1- father( tom ); 17 $p1- mother( karen ); 18 19 print $p1- name(),"\n"; 20 print $p1- father(),"\n"; 21 print $p1- mother(),"\n"; 22 23 my $p2 = new Person; 24 $p2- name("mery"); 25 $p2- father("startk"); 26 $p2- mother("guiness"); 27 28 print Dumper($p2); 配列の場合は、$p1- child(0, merry );$p1- child(1, ann );のように使う。ハッシュの場合は、$p1- note( key , value );のように使う。 オブジェクト指向 パッケージがクラス。newサブルーチンでインスタンスを作成する。newの中で無名のハッシュ参照を作成し、最初の引数のクラス名(パッケージ名)とblessする。blessは、ハッシュ参照とクラス名を関連付けた参照を返す。これがインスタンスの参照となる。インスタンスの参照からクラス内のサブルーチンを呼び出せる。 @ISAにスーパークラスを書き込むと、サブクラスになる。@ISAは、単に自分にないメソッドを探す順番を決めるために使われる。メソッドの探索は再帰的に行われる(親に親があれば、親の兄妹より先に探す)。フィールドは継承しない。複数のスーパークラスを継承できる。 【oo.pl】 1 #!/usr/local/bin/perl 2 # オブジェクト指向 3 4 # パッケージがクラスになる 5 use strict; 6 use util Person; # パーソンクラスを使う 7 use util Engineer; # エンジニアクラスを使う 8 9 # パーソンクラスを作成 10 my $ref = util Person- new("suna"); 11 12 # 名前を表示する 13 print "name ",$ref- getName,"\n"; 14 15 # 名前を変える 16 $ref- setName( "nao"); 17 18 # 名前を表示する 19 print "name ",$ref- getName,"\n"; 20 21 # エンジニアクラスを作成する 22 my $eref = util Engineer- new("nori"); 23 24 # 名前を表示する 25 print "name ",$eref- getName,"\n"; 26 27 # 名前を変える 28 $eref- setName( "non"); 29 30 # 名前を表示する 31 print "name ",$eref- getName,"\n"; 32 33 # スキルを設定する 34 my $skillref = ["db2","java","perl"]; 35 $eref- setSkill($skillref); 36 37 # スキルを表示する 38 my $eeref = $eref- getSkill; 39 for my $skill ( @$eeref ) { 40 print $skill,"\n"; 41 } 【util/Person.pm】 1 #!/usr/local/bin/perl 2 3 package util Person; 4 5 sub new { 6 my $clas = shift; 7 bless { 8 name = shift 9 }, $clas; 10 } 11 12 sub getName { 13 my $self = shift; 14 return $self- {name}; 15 } 16 17 sub setName { 18 my $self = shift; 19 $self- {name} = shift; 20 } 25 26 1; 【util/Engineer.pm】 1 #!/usr/local/bin/perl 2 3 package util Engineer; 4 5 @ISA = ("util Person"); 6 7 sub setSkill { 8 my ($self, $skillref) = @_; 9 $self- {skill} = $skillref; 10 } 11 12 sub getSkill { 13 my $self = shift; 14 return $self- {skill}; 15 } 16 17 1; 【実行結果】 [suna@athlon4 perl]$ ./oo.pl name suna name nao name nori name non db2 java perl 固定長ファイルの扱い 【asciiのみ】 fix.dat 11223334444555552122333444455555 上記ファイルを16バイト/レコードとして読み込む。 #!/usr/bin/perl # 固定長レコードのファイルを読み込む use strict; my $FILE = "fix.dat"; open IN, $FILE or die "file open error!! $FILE"; binmode IN; my $rec; my $TEMPLATE = "A1A1A2A3A4A5"; while( 1 ) { my $size = read IN, $rec, 16 ; if( $size == 0 or $rec == "\n") { last; } my @t = unpack $TEMPLATE, $rec; for my $term (@t) { print $term, ","; } print "\n"; } close IN; 実行結果 [foo@athlon4 perl]$ 3.pl 1,1,22,333,4444,55555, 2,1,22,333,4444,55555, 【Shift-JIS込み】 bin.dat 123山田太郎12345123磯野一郎12345 #!/usr/bin/perl # 固定長レコードのファイルを読み込む(Shift-JIS込み) use strict; use Encode; use encoding "utf-8"; my $FILE = "bin.dat"; open IN, $FILE or die "file open error!! $FILE"; binmode IN; my $rec; my $TEMPLATE = "A3a8A5"; while( 1 ) { my $size = read IN, $rec, 16 ; if( $size == 0 or $rec == "\n") { last; } my @t = unpack $TEMPLATE, $rec; my $i = 0; for my $term (@t) { $i++; if( $i == 2 ) { $term = decode("cp932", $term); } print $term, ","; } print "\n"; } close IN; 実行結果 [foo@athlon4 perl]$ 4.pl 123,山田太郎,12345, 123,磯野一郎,12345, Win -- Unixファイル変換 perl -pe s/\r\n/\r/ winfile unixfile ShiftJiSを使う http //www.fl.reitaku-u.ac.jp/~schiba/perl/perlEncoding.html より perl5.8.1以上 use encoding "shiftjis"; binmode STDERR, " encoding(shiftjis)"; use Encode decode ; while ( IN ) { # ファイルからの入力にエンコードを指定する。ここでは shiftjis を指定しているが, # 入力ファイルのエンコードにあわせ,euc-jp なども指定可能。 $line = decode( shiftjis , $_); print $line; # 標準出力なので encoding プラグマにより Shift JIS に自動変換される。 } close (IN); #!/usr/bin/perl use Encode; open IN, "/home/suna/tmp/wiki.txt"; while( $line = IN ) { $line = decode( cp932 , $line); # Shift-JIS(cp932)をutf-8に変換 chomp $line; print $line, "\n"; } close IN; pack, unpackの TEMPLATE TEMPLATEは、 型 説明 a 任意のバイナリデータ。null(\0?)がパディングされる A ASCII文字。空白がパディングされる。 b ビット文字。昇順のビットオーダ。 B ビット文字。降順のビットオーダ。 h 16進文字。低位の4ビットが先。 H 16進文字。高位のの4ビットが先。 c サイン付キャラクタ。 C サインなしキャラクタ。 s signed short S unsigned short i signed integer I unsigned integer l signed long L unsigned long ENCODING 以下を使って求めた。perldoc Encode参照 #!/usr/bin/perl use Encode; @with_jp = Encode- encodings("Encode JP"); for $encoding (@with_jp) { print $encoding, "\n"; } 項目 説明 7bit-jis ascii ascii-ctrl cp932 euc-jp iso-2022-jp iso-2022-jp-1 iso-8859-1 jis0201-raw jis0208-raw jis0212-raw MacJapanese null shiftjis utf-8-strict utf8 関数 項目 説明 read FILEHANDLE,SCALAR,LENGTH[,OFFSET] FILEHANDLEからLENGTHバイト読み込んで変数SCALARに保管する。OFFSET指定するとSCALARの先頭からOFFSET位置から更新する。読み込んだバイト数を返す。ファイル終端では0を返す。 pack TEMPLATE,LIST LISTをTEMPLATEに指定した形式で変数に格納し返す。 unpack TEMPLATE, EXPR 変数EXPRをTEMPLATEに従って配列に展開する。 Encode encode(ENCODING, $string [, CHECK]) ENCODINGに従って$stringをエンコードして返す。CHECK?? Encode decode(ENCODING, $string [, CHECK]) ENCODINGに従って$stringをデコードして返す。 その他 項目 説明 複数行に渡るコメント コメントの最初:=pod,コメントの最後:=cut
https://w.atwiki.jp/yotagarao/pages/114.html
perl ファイル読み込み fastaファイルの処理 フォルダの中を一気に読み込む
https://w.atwiki.jp/gemu/pages/66.html
CGIとは 主にperl言語で作られたゲームや掲示板のこと たいていのHPにある。 有名なやつといえばFFBATTLEや三国志NET、箱庭諸島など The wars of roses The wars of roses edgs+?
https://w.atwiki.jp/ibibi/pages/21.html
#!/usr/bin/perl #----------------------------------------------------------------- #CGI環境 use lib /usr/local/lib/perl/cgi-lib ; use CGI; #----------------------------------------------------------------- #CGI変数の取り込み $query = new CGI; $utterance = $query- param( utterance ); #$utterance = "あなたのお名前は何ですか?"; #----------------------------------------------------------------- #CGI変数をファイル"user.txt"に書き込む open(USER, " user.txt"); print USER "$utterance\n"; close(USER); #"user.txt"の文字コードをEUCに変えて"user.euc"として保存 system("nkf -euc user.txt user.euc"); #"user.euc"の内容をchasenで形態素解析 $i=0; open(CHASEN,"/usr/local/bin/chasen user.euc |"); while( CHASEN ){ chop(); ($syutsugen[$i],$yomi[$i],$daihyou[$i],$pos[$i])=split(/\t/); $i++; } close(CHASEN); $wordnum=$i; #----------------------------------------------------------------- #ここに対話処理を書く $keyword1="固有名詞"; $keyword2="地域"; $keyflag1=0; $keyflag2=0; for($j=0;$j $wordnum;$j++){ if($pos[$j] eq $keyword1){ $keyflag1=1; } if($pos[$j] eq $keyword2){ $keyflag2=1; } } if(($keyflag1 ==1) ($keyflag2 == 1)){ $system = "OK"; } $keyword1="固有名詞"; $keyword2="地域"; $keyflag1=0; $keyflag2=0; for($j=0;$j $wordnum;$j++){ if($pos[$j] eq $keyword1){ $keyflag1=1; } if($pos[$j] eq $keyword2){ $keyflag2=1; } } if(($keyflag1 ==1) ($keyflag2 == 1)){ $system = "OK"; } #----------------------------------------------------------------- #HTML出力 print "Content-type text/html\n\n"; print " HTML \n"; print " TITLE 対話システム /TITLE \n"; print " BODY \n"; print " H1 対話システム /H1 \n"; print "User "; for($j=0;$j $wordnum;$j++){ print "$syutsugen[$j] "; } print " BR \n"; print " BR \n"; print "User Word \n"; print " BR \n"; for($j=0;$j $wordnum;$j++){ print "$daihyou[$j]\t$yomi[$j]\t$pos[$j]\n"; print " BR \n"; } print "System "; print "$system\n"; print " BR \n"; print " HR \n"; print "発話を入力してTalkボタンをクリックして下さい。\n"; print FORM NAME="form" METHOD="POST" ACTION="dialogue.cgi" ; print INPUT TYPE="text" NAME="utterance" SIZE="50" VALUE="" ; print INPUT TYPE="submit" NAME="submit" VALUE="Talk" ; print /FORM ; print " /BODY \n"; print " /HTML \n";
https://w.atwiki.jp/raycy/pages/59.html
http //books.google.com/books?lr= hl=ja as_brr=0 as_pt=ALLTYPES q=%22stick+fast%22+typewriter btnG=%E6%9B%B8%E7%B1%8D%E3%81%AE%E6%A4%9C%E7%B4%A2 A Study of the Two-letter Sequences in Written English Used as a Basis for ... - 2 ページ Wilson Alexander Moran 著 - 1930 - 91 ページ ... the Sholes models was to collide and stick fast at the printing point, ... Herkimer County Historical Society, The Story of the Typewriter, 1873-1923. ... http //books.google.com/books?lr= hl=ja as_brr=0 as_pt=ALLTYPES q=%22stick+fast%22+typewriter btnG=%E6%9B%B8%E7%B1%8D%E3%81%AE%E6%A4%9C%E7%B4%A2 A Study of the Two-letter Sequences ... - Google ブック検索 http //books.google.com/books?id=cK1HAAAAMAAJ q=%22stick+fast%22+typewriter dq=%22stick+fast%22+typewriter lr= as_brr=0 as_pt=ALLTYPES ei=3P1fSaW_GZbskgS65cWGCw hl=ja pgis=1 http //books.google.com/books?id=cK1HAAAAMAAJ hl=ja pgis=1 A Study of the Two-letter Sequences in Written English Used as a Basis for ... 著者 Wilson Alexander Moran 詳細 A Study of the Two-letter Sequences in Written English Used as a Basis for an Estimate of the Efficiencies of the Universal Typewriter Keyboard and of a Suggested Revision 著者 Wilson Alexander Moran 出版社 University of Wisconsin, 1930 ウィスコンシン大学 - マディソン の蔵書 デジタル化 2007年8月29日 91 ページ A study of the two-letter sequences in written English used as a basis for an estimate of the efficiencies of the universal typewriter keyboard and of suggested revision. by Wilson Alexander Moran Type Thesis/dissertation Microfilm; English Publisher Madison, Wis. University of Wisconsin, 1930 Dissertation Thesis (Ph.M)--University of Wisconsin. http //madcat.library.wisc.edu/cgi-bin/Pwebrecon.cgi?BBID=6384100
https://w.atwiki.jp/fmemo/pages/63.html
改行コードを変換するワンライナー Perlにおける真偽値 正規表現量指定子 コマンドラインオプション-eオプション -n オプション -p オプション -l オプション perldocの使い方 バイナリファイルの読み書き参考サイト エンディアン変換参考サイト 改行コードを変換するワンライナー Mac OS 9以前の改行コードである\rをUnix(Mac OS X)の改行コードである\nに変換したい場合。 $ perl -pe s/\r/\n/g inputfile outputfile Perlにおける真偽値 Perlにおける真偽値の定義は以下のとおり undef(未定義値)は偽 数値の0, 文字列の0,空の文字列""は偽 上記の3つ以外は真 use strict; use warnings; my $var1 = undef; my $var2 = 0; my $var3 = "0"; my $var4 = ""; my $var5 = 1; my $var6 = "aa"; if( $var1 ){ print "true\n"; }else{ print "false\n"; } if( $var2 ){ print "true\n"; }else{ print "false\n"; } if( $var3 ){ print "true\n"; }else{ print "false\n"; } if( $var4 ){ print "true\n"; }else{ print "false\n"; } if( $var5 ){ print "true\n"; }else{ print "false\n"; } if( $var6 ){ print "true\n"; }else{ print "false\n"; } このプログラムを実行させると、 $ perl truefalse.pl false false false false true true 正規表現 ^ 行頭 $ 行末 \w アルファベット(大文字小文字)、数字、アンダーバー。つまり[a-zA-Z_]と同値 \d 数字。[0-9]と同値 \s 空白文字(スペース、タブ、改行) . 改行以外の任意の文字 量指定子 + 1回以上の繰り返し * 0回以上の繰り返し ? 0回または1回の繰り返し コマンドラインオプション -eオプション その後にある文字列をプログラムだとして認識し、実行する。ワンライナーを書くときに使う。 $ perl -e print "hello\n" hello -n オプション プログラムの前後にwhile( ){ ... }があると解釈する。-eと組み合わせてワンライナーで使うことが多い。 -p オプション nオプションに似ているが、最後に評価した式を出力する。-eと組み合わせてワンライナーで使うことが多い。 -l オプション 改行を付加する。 perldocの使い方 perldocについて知りたい時 $ peldoc perldoc 関数を調べたい時 $ perldoc -f sort ソースをそのまま読みたい時 $ perldoc -u sort モジュールのパスを知りたい時 $ perldoc -l sort バイナリファイルの読み書き use strict; use warnings; my @names = ( Alice , Bob , Charlie ); my @nums = (10, 20, 30); open my $fh, , binary-test or die "file open error $!"; binmode $fh; for (my $i=0; $i 3; $i++){ my $buffer = pack "a8 l", $names[$i], $nums[$i]; print $fh $buffer; } close $fh; pack関数の書式は perldoc -f packで確認できる。 参考サイト http //www.geocities.jp/ky_webid/perl5/018.html エンディアン変換 use strict; use warnings; if(@ARGV != 3){ print "You need 3 arguments.\n"; print "\$ perl endian.pl inputfile outputfile num\n"; exit; } my ($ifile, $ofile, $num) = @ARGV; open my $in, , "$ifile"; open my $out, ,"$ofile"; if($num==2){ while(read($in,my $buf,2)){ print $out pack("n",unpack("v",$buf)); } }elsif($num==4){ while(read($in,my $buf,4)){ print $out pack("N",unpack("V",$buf)); } }else{ print "the 3rd argument should be 2 or 4.\n"; } 参考サイト http //garbagedays.dreamlog.jp/archives/4465827.html
https://w.atwiki.jp/macdemysql6/pages/15.html
Perl perlからいろいろなDB操作を行う。 DBIのインストール cpanのページからDBIモジュールをMacOSにインストールする。 ”DBI-1.609.tar.gz”こんな感じのファイルをダウンロードし、インストール。READMEを読もう。簡単にインストールができるはず。 DBD-mysqlのインストール cpanのページからDBD-mysqlモジュールをダウンロードし、インストールする。こいつはインストールがよくわからない。DBIのインストールだけでは、MySQLサーバに接続できないのでDBIとセットでインストールする必要あり。 とりあえず、perl Makefile.PL- make- make installでインストールできたけど。 Digestのインストール cpanのページからDigestをダウンロードし、いつもの通りインストール。READMEには具体的なコマンドが書かれていなかったので備忘録をば、、、 siro ~/Unix/build/Digest-1.16 Pipin$ perl Makefile.PL siro ~/Unix/build/Digest-1.16 Pipin$ make siro ~/Unix/build/Digest-1.16 Pipin$ make test All tests successful. siro ~/Unix/build/Digest-1.16 Pipin$ sudo make install Password Writing //System/Library/Perl/5.8.6/darwin-thread-multi-2level/auto/Digest/.packlist Appending installation info to //System/Library/Perl/5.8.6/darwin-thread-multi-2level/perllocal.pod Perlスクリプト Step1 コネクト これができなきゃ始まらない。 #!/usr/bin/perl use DBI; my $rdb= DBI mysql gdb ; my $user= mysql ; my $pass= mysql ; # open mysql connection $dbh = DBI- connect($rdb, $user, $pass) or die "Cannt connect to MySQL"; # close mysql connection $dbh- disconnect;
https://w.atwiki.jp/fattencho/pages/15.html
Perl ワンライナー エンコード echo "@" | perl -ne s/([^\w ])/"%".unpack("H2",$1)/eg;s/ /\+/g;print;print "\n"; デコード perl -MURI Escape -wle print uri_unescape $ARGV[0] http //ja.wikipedia.org/wiki/%E3%81%93%E3%81%88%E9%83%A8 # perlでデーモン作成 #!/usr/local/bin/perl use strict; use warnings; my $PID; my $PID_FILE = "/home/fattencho/daemon.pid"; my $SLEEP_INTERVAL = 10; main(@ARGV); exit(0); sub main { my ($act) = @_; $act ||=""; if ($act eq "start"){ #daemonの起動 #複数の起動はできません if( get_pid_file() ){ print "$0 is already running\n"; return; } init(); action(); return; } if ($act eq "stop"){ #daemonの停止 my $pid = get_pid_file(); if(not defined $pid){ print "$0 is not running\n"; return; } #pid fileを削除すると、後でkillされます return del_pid_file(); } print "usage $0 [start|stop]\n"; return; } sub init { my $pid = fork; # Fork failure. if($pid 0){ exit -1; } # Fork success. elsif($pid){ exit 0; } #signal送信時に実行するmethod $SIG{INT} = $SIG{HUP} = $SIG{QUIT} = $SIG{KILL} = $SIG{TERM} = interrupt ; $PID = $$; set_pid_file($PID); } sub action { while(1) { sleep($SLEEP_INTERVAL); #pidファイルが削除されていれば、自分自身をkillします if (not get_pid_file() ){ kill $PID; return; } } } sub interrupt { my ($sig) = @_; $SIG{$sig} = IGNORE ; return del_pid_file(); } sub get_pid_file { #pid fileの名称とpidの取得 return undef if not -e $PID_FILE; open my $fh, $PID_FILE or die "can t open $PID_FILE $!"; my ($line) = $fh ; close $fh or die "can t close $PID_FILE $!"; my ($pid) = $line =~ /(\d+)/o; return ($PID_FILE,$pid); } sub get_pid_file { #pid fileの名称とpidの取得 return undef if not -e $PID_FILE; open my $fh, $PID_FILE or die "can t open $PID_FILE $!"; my ($line) = $fh ; close $fh or die "can t close $PID_FILE $!"; my ($pid) = $line =~ /(\d+)/o; return ($PID_FILE,$pid); } sub set_pid_file { #pid fileにpidを書き込み my ($process_id) = @_; open my $fh, " $PID_FILE" or die "can t open $PID_FILE $!"; print $fh $process_id; close $fh or die "can t close $PID_FILE $!"; } sub del_pid_file { unlink $PID_FILE or die "can t unlink $PID_FILE $!"; } 1;
https://w.atwiki.jp/honeybe/pages/19.html
perlTips配列の要素数を取る。 正規表現で置換 日付計算:月末日を算出する。 外部プログラムを実行する。 参考URL なにかあればどうぞ perl Tips 配列の要素数を取る。 print @hoge; 配列変数(@hoge)を参照すれば配列の要素数が分かる。 引数チェックなどに使用する。 if (@ARGV 2) { print "Usage hoge.pl hoge moge\n"; exit; } 正規表現で置換 $hoge =~ s/[\/ ]/-/g $hoge内の/と を-に置き換える。 s/で置換開始。 最後の/後はオプション。代表的なオプションは下記。g 繰り返し。可能な限りマッチさせ、置換する。 i 大文字小文字の区別をしない。 日付計算:月末日を算出する。 http //www.futomi.com/subroutine/getlastday.html 参照。 外部プログラムを実行する。 exec system `(backtick演算子) $result = `ls -la /tmp/` 参考URL http //www.site-cooler.com/kwl/perl/ http //www.stackasterisk.jp/tech/program/perl01_01.jsp なにかあればどうぞ 名前 コメント
https://w.atwiki.jp/wiki5_hks/pages/38.html
Perl のテキスト 結城浩,Perl言語プログラミングレッスン 入門編,ソフトバンクパブリッシング http //d.hatena.ne.jp/asin/4797312211 Perl の入手先 ActivePerl http //www.activestate.com/Products/ActivePerl/